// GPRS参数同步
var PageTimer = {
    id: "PageTimer", //页面id
    menu: "i18n.lan.menu.other", //所属菜单(一级菜单名)
    title: "i18n.lan.menu.PageTimer", //标题（二级菜单名）
    parentIcon: "icon-me-usercmd", //一级菜单图标
    icon: "icon-me-interval", //图标
    refreshBtnCmd: "DUMP_CORE", //刷新按钮指令
    saveBtn: true, //保存按钮
    el: [ //控件
        {
            elname: "datagrid",
            rowCount: Device.getNodesCount("timer"),
            data: {
                width: 810,
                height: 400,
                columns: [
                    [{
                            field: 'index',
                            width: 40,
                            align: "center",
                        },
                        {
                            field: "Dow",
                            formatter:Easyui.formatter.combobox,
                            editor: new Easyui.editor.Combobox(i18n.lan.PageTimer.weekTypeItemsKV),
                            dumpKey: "TIMER<n>SET",
                            dumpParamIndex: 0,
                            cmdKey: "TIMERSET<n>,",
                            otherFields:"hour,min,sed,to,type,act",
                            width:80,
                        },
                        {
                            field: "hour",
                            editor:Easyui.editor.numberbox,
                            dumpKey: "TIMER<n>SET",
                            dumpParamIndex: 1,
                            width:80,
                        },                        
                        {
                            field: "min",
                            editor: Easyui.editor.numberbox,
                            dumpKey: "TIMER<n>SET",
                            dumpParamIndex: 2,
                            width:80,
                        },
                        {
                            field: "sed",
                            editor:Easyui.editor.numberbox,
                            dumpKey: "TIMER<n>SET",
                            dumpParamIndex: 3,
                            width:80,
                        },
                        {
                            field: "type",
                            formatter: Easyui.formatter.combobox,
                            editor: new Easyui.editor.Combobox(i18n.lan.PageTimer.timerTypeItemsKV),
                            dumpKey: "TIMER<n>SET",
                            dumpParamIndex: 5,
                            width:150,
                        },
                        {
                            field: "act",
                            formatter: Easyui.formatter.combobox,
                            // editor: new Easyui.editor.Combobox(i18n.lan.PageTimer.actTypeItemsKV),
                            editor: new Easyui.editor.Combobox(Device.getTimerActionTypeItems()),
                            dumpKey: "TIMER<n>SET",
                            dumpParamIndex: 6,
                            width:160,
                        },
                        {
                            field: "to",
                            editor:Easyui.editor.numberbox,
                            dumpKey: "TIMER<n>SET",
                            dumpParamIndex: 4,
                            width:120,
                        },
                    ]
                ],
            }
        },
    ],
}
CmdPage.add(PageTimer); //添加到页面管理